package MyArray;

import java.util.Arrays;

/**打印阶梯
 * @author Raymond
 * @create 2025/2/28 14:09
 */
public class TwoDimensionalArray03 {
    public static void main(String[] args) {
        int[][] arr = new int[3][];
        for (int i = 0; i < arr.length; i++) {
            arr[i] = new int[i+1];
            for (int j = 1; j <= arr[i].length; j++) {
                arr[i][j-1] = j;
            }
        }
        for (int i = 0; i < arr.length; i++) {
            for (int j = 0; j < arr[i].length; j++) {
                System.out.print(arr[i][j]+" ");
            }
            System.out.println();
        }
    }
}
